void PauseGame () { Time.timeScale = 0f; AudioListener.pause = true; } void ResumeGame () { Time.timeScale = 1; AudioListener.pause = false; }Copy